package com.cloudbroker.bcs.platform.ltb.bizapi.constants.type;

/**
 * Created by world on 16/12/8.
 */

/**
 * 排序业务类别
 */
public enum RecommendBizType {
    ADVISER("1","投顾排序"),
    COMBINE("2","组合排序"),
    VIEWPOINT("3","观点排序");

    private final String val;

    private final String description;

    private String toString;

    RecommendBizType(String val, String description) {
        this.val = val;
        this.description = description;
    }

    public String getVal() {
        return val;
    }

    public String getDescription() {
        return description;
    }

    public static RecommendBizType getByValue(String val) {
        if (val==null||val.equals("")){
            return null;
        }
        for(RecommendBizType type : values()) {
            if( type.getVal().equals(val) ) {
                return type;
            }
        }
        return null;
    }
    @Override
    public String toString() {
        return "RecommendBizType{" +
                "val='" + val + '\'' +
                ", description='" + description + '\'' +
                ", toString='" + toString + '\'' +
                '}';
    }
}
